<template>
    <div>
        <vheader :ismini="iscollapse" :clientWidth="clientWidth"></vheader>
        <el-container style="border:0px solid #e3e3;">
            <el-main style="width:100%;">
                <el-collapse v-model="activeNames">
                    <el-collapse-item :title="item.title" :name="index" v-for="(item,index) in updatelist">
                        <div v-for="c in item.items">{{c}}</div>
                    </el-collapse-item>
                </el-collapse>
            </el-main>
        </el-container>
        <vfooter></vfooter>
    </div>
</template>

<script>
import vheader from "../common/Header";
import vfooter from "../common/Footer";
export default {
  data() {
    return {
      iscollapse: false,
      clientWidth:1300,
      activeNames:[0],
      updatelist: [
        {
          title: "2019-06-18 21:14 v0.0.1-3alphal",
          items:[
            "1、新增首页，解决首页响应式问题",
            "2、解决core升级之后接口bug",
            "3、调整详情页面的布局和响应式问题；"
          ]
        },
        {
          title: "2019-06-17 19:14 v0.0.1-3alphal",
          items:[
            "1、新增主题列表",
            "2、解决core升级之后接口bug"
          ]
        },
        {
          title: "2018-10-22 12:44 v0.0.1-2alphal",
          items: [
            "1、优化属性关联，实现主题-属性多对多的关系",
            "2、跳转内容保存功能"
          ]
        },
        {
          title: "2018-09-21 17:44 v0.0.1-2alphal",
          items: ["1、新增支持部分响应式布局方式"]
        },
        {
          title: "2018-09-20 20:00 v0.0.1-1alphal",
          items: ["1、新增对比列表瀑布流布局"]
        }
      ]
    };
  },
  mounted: function() {
    this.activeNames = [];
    for (let index = 0; index < this.updatelist.length; index++) {
      this.activeNames.push(index);
    }

    let self = this;
    window.onresize = function() {
      self.clientHeight = window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight;
      self.clientWidth = document.documentElement.clientWidth;
      $(".el-main").height(self.clientHeight - 140);

      //获取宽度
      self.iscollapse = self.clientWidth < 768;
    };
    window.onresize();
  },
  components: { vheader,vfooter }
};
</script>

<style scoped>

</style>